home *** CD-ROM | disk | FTP | other *** search
- /*
- $VER: cleanram.dopus 2.0
- */
-
- options results /* need results */
-
- /* this library is needed for statef function */
-
- if ~show('l','rexxsupport.library') then /* check if lib is loaded */
- call addlib('rexxsupport.library',0,-30) /* if not, load it */
-
- /* call to the Wb delete command */
- address command 'delete ram:~(ENV|T|Clipboards|Disk.info) ALL'
-
- status 3
- win=result /* get active dopus window */
-
- status 13 win
- currentdir=result /* get this window directory */
- basedir = upper(left(currentdir,3)) /* Ram disk: or RAM: -> RAM */
-
- if basedir = 'RAM' then /* if we are somewhere in ram: */
- do
- existdir = left(statef(currentdir),3) /* check if the dir still exists */
- if existdir ~= 'DIR' then /* if we can't find it no more */
- scandir 'RAM:' /* we go back in RAM: */
- else
- rescan /* reread the current dir */
- end
-
- status 13 1-win /* get the other window */
- currentdir=result
- basedir = upper(left(currentdir,3)) /* Ram dir/RAM -> RAM */
- if basedir = 'RAM' then
- do
- otherwindow /* make the other window active */
- existdir = left(statef(currentdir),3)
- if existdir ~= 'DIR' then
- scandir 'RAM:'
- else
- rescan
- otherwindow /* we go back in our window */
- end
-